<template>
  <div class="_abs-c-two _wrapper _background-5" v-if="!$comStore.login.token">
    <div class="_abs _abs-c _flex-y _background-1 _p20 _radius-15b">
      <div>登录</div>
      <div class="_m-t-20">
        <el-input v-model="loginData.username" placeholder="请输入账号" />
      </div>
      <div class="_m-t-20">
        <el-input
          v-model="loginData.password"
          placeholder="请输入密码"
          type="password"
        />
      </div>
      <div class="_m-t-20 _wrapper-x">
        <el-button
          class="_wrapper-x"
          type="primary"
          @click="$comStore.login.login(loginData)"
          >登录</el-button
        >
      </div>
    </div>
  </div>
</template>

<script>
export default {
  data() {
    return {
      loginData: {},
    };
  },
};
</script>

<style>
.login-box {
  background: rgb(0, 0, 0, 0.2);
  top: 0;
  left: 0;
}
</style>
